#include<stdio.h>
#include<conio.h>
long arr[100000];
long n,k,cach=1,max,i,a;    
int main(){
    scanf("%ld%ld",&n,&k);
    max=(n-1)/(k+1)+1;
    for(i=1;i<=max;i++){
        arr[i]=n-((i-1)*k+i)+1;
        
        a=(n-((i-1)*k+i))*i+1;
        printf("%ld \t",a);
        cach+=a;
        cach%=2111992l;
    }
    printf("\n%ld",cach);
    getch();
    return 0;
}
